﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Media.Media3D;
using System.Windows.Media.Animation;

namespace Gronia.WPF.Controls
{
    [TemplatePart(Name = "PART_BusyImage", Type = typeof(Image))]
    [TemplatePart(Name = "PART_BusyImageVisual", Type = typeof(Viewport2DVisual3D))]
    [TemplatePart(Name = "PART_BusyLoadingImage", Type = typeof(Image))]
    public partial class BusyIndicator : ContentControl
    {
        #region Constructors
        static BusyIndicator()
        {
            DefaultStyleKeyProperty.OverrideMetadata(typeof(BusyIndicator), new FrameworkPropertyMetadata(typeof(BusyIndicator)));
        }
        #endregion

        #region Overrides
        public override void OnApplyTemplate()
        {
            base.OnApplyTemplate();
            PART_BusyImage = GetTemplateChild("PART_BusyImage") as Image;
            PART_BusyLoadingImage = GetTemplateChild("PART_BusyLoadingImage") as Image;
            PART_BusyImageVisual = GetTemplateChild("PART_BusyImageVisual") as Viewport2DVisual3D;
        }
        #endregion

        #region PARTS
        private Image PART_BusyImage;
        private Image PART_BusyLoadingImage;
        private Viewport2DVisual3D PART_BusyImageVisual;
        private Storyboard story = new Storyboard();
        #endregion
    }
}